import java.util.Scanner;
class  Jin03 {
	public static void main(String[] args){
		Scanner scan = new Scanner(System.in);
		int a = scan.nextInt();
		if (80<a<=100){
			System.out.println("A");
		}
		else if (70<a<=80){
			System.out.println("B");
		}
		else if (60<a<=70){
			System.out.println("C");
		}
		else{
		System.out.println("D");
		}
		scan.close();
	}
}